package com.qsl;

/**
 * @Description:
 * @Author: 青石路
 * @CreateDate: 2022/5/21 11:07
 **/
public class TmpDirTest {

    public static void main(String[] args) {
        /*String tempDir = System.getProperty("java.io.tmpdir");
        System.out.println(tempDir);

        File file = new File(AccessController.doPrivileged(new GetPropertyAction("java.io.tmpdir")));
        System.out.println(file);*/

        String ossFilePath = "UserData/213/20220507/ZCFZB20220507.xlsx.zip";
        String prefix = ossFilePath.substring(ossFilePath.lastIndexOf("/")+1);
        String suffix = ossFilePath.substring(ossFilePath.lastIndexOf("."));
        System.out.println(prefix);
        System.out.println(suffix);
    }
}
